<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>posix::basic_descriptor::native_non_blocking (1 of 3 overloads)</title>
    <link rel="stylesheet" href="../../../../boostbook.css" type="text/css">
    <meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
    <link rel="home" href="../../../../index.html" title="Asio">
    <link rel="up" href="../native_non_blocking.html" title="posix::basic_descriptor::native_non_blocking">
    <link rel="prev" href="../native_non_blocking.html" title="posix::basic_descriptor::native_non_blocking">
    <link rel="next" href="overload2.html" title="posix::basic_descriptor::native_non_blocking (2 of 3 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%">
    <tr>
        <td valign="top"><img alt="asio C++ library" width="250" height="60" src="../../../../asio.png"></td>
    </tr>
</table>
<hr>
<div class="spirit-nav">
    <a accesskey="p" href="../native_non_blocking.html"><img src="../../../../prev.png" alt="Prev"></a><a accesskey="u"
                                                                                                          href="../native_non_blocking.html"><img
        src="../../../../up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img
        src="../../../../home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../next.png"
                                                                                              alt="Next"></a>
</div>
<div class="section">
    <div class="titlepage">
        <div>
            <div><h5 class="title">
                <a name="asio.reference.posix__basic_descriptor.native_non_blocking.overload1"></a><a class="link"
                                                                                                      href="overload1.html"
                                                                                                      title="posix::basic_descriptor::native_non_blocking (1 of 3 overloads)">posix::basic_descriptor::native_non_blocking
                (1 of 3 overloads)</a>
            </h5></div>
        </div>
    </div>
    <p>
        Gets the non-blocking mode of the native descriptor implementation.
    </p>
    <pre class="programlisting"><span class="keyword">bool</span> <span
            class="identifier">native_non_blocking</span><span class="special">()</span> <span
            class="keyword">const</span><span class="special">;</span>
</pre>
    <p>
        This function is used to retrieve the non-blocking mode of the underlying
        native descriptor. This mode has no effect on the behaviour of the descriptor
        object's synchronous operations.
    </p>
    <h6>
        <a name="asio.reference.posix__basic_descriptor.native_non_blocking.overload1.h0"></a>
        <span><a name="asio.reference.posix__basic_descriptor.native_non_blocking.overload1.return_value"></a></span><a
            class="link"
            href="overload1.html#asio.reference.posix__basic_descriptor.native_non_blocking.overload1.return_value">Return
        Value</a>
    </h6>
    <p>
        <code class="computeroutput"><span class="keyword">true</span></code> if the underlying descriptor
        is in non-blocking mode and direct system calls may fail with <code class="computeroutput"><span
            class="identifier">asio</span><span class="special">::</span><span class="identifier">error</span><span
            class="special">::</span><span class="identifier">would_block</span></code> (or the equivalent system
        error).
    </p>
    <h6>
        <a name="asio.reference.posix__basic_descriptor.native_non_blocking.overload1.h1"></a>
        <span><a name="asio.reference.posix__basic_descriptor.native_non_blocking.overload1.remarks"></a></span><a
            class="link"
            href="overload1.html#asio.reference.posix__basic_descriptor.native_non_blocking.overload1.remarks">Remarks</a>
    </h6>
    <p>
        The current non-blocking mode is cached by the descriptor object. Consequently,
        the return value may be incorrect if the non-blocking mode was set directly
        on the native descriptor.
    </p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%">
    <tr>
        <td align="left"></td>
        <td align="right">
            <div class="copyright-footer">Copyright © 2003-2022 Christopher M. Kohlhoff<p>
                Distributed under the Boost Software License, Version 1.0. (See accompanying
                file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
            </p>
            </div>
        </td>
    </tr>
</table>
<hr>
<div class="spirit-nav">
    <a accesskey="p" href="../native_non_blocking.html"><img src="../../../../prev.png" alt="Prev"></a><a accesskey="u"
                                                                                                          href="../native_non_blocking.html"><img
        src="../../../../up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img
        src="../../../../home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../next.png"
                                                                                              alt="Next"></a>
</div>
</body>
</html>
